Libraries

Load the libraries that will be needed.

library(readxl)
library(tidyr)
library(plotly)

Data

Women’s suffrage data was extracted from Wikipedia (https://en.wikipedia.org/wiki/Timeline_of_women%27s_suffrage). Information is stored in a dataset named “data” and then filtered to include only countrywide and full right events (since some countries approved women’s suffrage with restrictions at the beginning).

data <- read_excel("D:/IWD.xlsx", sheet <- "Sheet1")
data<-filter(data, Level=="Countrywide", Type=="Full")

Map

World map focused in the Americas is displayed including a color scale indicating the year when full rights to vote in political elections where granted for women nationwide.

plot_ly(data, type='choropleth',locations=data$Code,z=data$Year, text=data$Country, color=data$Year, colorscale="reds")%>%
  layout(geo=list(lonaxis=list(range=c(-180,0))))